comment
authorJoey Hess <joeyh@joeyh.name>
Mon, 13 Jan 2025 17:32:46 +0000 (13:32 -0400)
committerJoey Hess <joeyh@joeyh.name>
Mon, 13 Jan 2025 17:32:46 +0000 (13:32 -0400)
doc/todo/Support___40__globally_configured__41_____34__annex_init__34___hooks/comment_2_0015660a3ede2c3181f960b9c2bac81c._comment
doc/todo/Support___40__globally_configured__41_____34__annex_init__34___hooks/comment_4_c62cc81e02c0d1906a747426e73102af._comment [new file with mode: 0644]

index b04bfbab976d5f4a4c7e7e599eb3cbd74f35672f..f57ea2c56c2b653fdfa72780a8510b05dcc3bfd2 100644 (file)
@@ -22,6 +22,4 @@ Worth bearing in mind that if such a hook output to stdout, or read from
 stdin, or for that matter was interactive on /dev/tty, it could badly
 mess up things that use git-annex as plumbing. Including git, in the case
 of the smudge filter.
-
-(Should this todo be tagged repronim btw?)
 """]]
diff --git a/doc/todo/Support___40__globally_configured__41_____34__annex_init__34___hooks/comment_4_c62cc81e02c0d1906a747426e73102af._comment b/doc/todo/Support___40__globally_configured__41_____34__annex_init__34___hooks/comment_4_c62cc81e02c0d1906a747426e73102af._comment
new file mode 100644 (file)
index 0000000..4a7d845
--- /dev/null
@@ -0,0 +1,21 @@
+[[!comment format=mdwn
+ username="joey"
+ subject="""comment 4"""
+ date="2025-01-13T17:20:28Z"
+ content="""
+Yes, a single pre-hook that gets run by every command would not be great
+for performance. Especially when git is eg sometimes running `git-annex
+smudge` repeatedly.
+
+You earlier spoke of "overall hook for git-annex invocation within a
+repo". Did you just mean a hook that runs before initialization, and not
+a hook that runs before every git-annex command?
+
+I feel more comfortable with adding a pre-init hook than pre-everything
+hooks. For one thing, it makes sense for that hook to prevent
+initialization if there is a reason to want to avoid that. It makes a lot
+less sense for a `pre-smudge` hook to prevent that bit of git-annex
+plumbing from working, which can have very different effects depending on
+what git is doing, or for a `pre-find` hook to output something to
+stdout.
+"""]]